# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=texmaker
pkgver=5.1.4
pkgrel=0
pkgdesc="Free cross-platform LaTeX editor since 2003"
url="https://www.xm1math.net/texmaker/index.html"
# qt6-qtwebengine-dev not avail
arch="aarch64 x86_64"
license="GPL-2.0-or-later"
depends="desktop-file-utils"
makedepends="
	poppler-qt5-dev
	qt6-qt5compat-dev
	qt6-qtbase-dev
	qt6-qtdeclarative-dev
	qt6-qttools-dev
	qt6-qtwebengine-dev
	"
source="https://www.xm1math.net/texmaker/$pkgname-$pkgver.tar.bz2
	musl-1.2.3.patch
	"
builddir="$srcdir/$pkgname-$pkgver"

build() {
	qmake6 PREFIX=/usr texmaker.pro
	make
}

check() {
	make check
}

package() {
	mkdir -p "$pkgdir/usr/share"
	make INSTALL_PATH="$pkgdir" INSTALL_ROOT="$pkgdir" PREFIX="/usr" install
}

sha512sums="
6ae4be7ae9be98e494480d4574e783a5568f0dcc9c631ccbc9bf00cca9f69dc672ba72060c064748a4446d20302af89e3bc6f14e8977d1f1ddbd20458fcf6d4e  texmaker-5.1.4.tar.bz2
6cad0857469f9648aa6c2d2f5f69602a32d4d5be6745b14b6bbf812ad45f34b9c8a886ddb0880fabee8dd7a8d08dc12782d7cb03dfe9c2462e914712cd8f663d  musl-1.2.3.patch
"
